package com.resign.carl.facade.manager.impl;

import com.resign.carl.facade.entity.User;
import com.resign.carl.facade.manager.UserManager;
import com.resign.carl.facade.service.LoginHistoryService;
import com.resign.carl.facade.service.UserSerivce;
import com.resign.carl.facade.service.impl.LoginHistoryServiceImpl;
import com.resign.carl.facade.service.impl.UserServiceImpl;

/**
 * Created by carl.zhao on 2016/6/15.
 */
public class UserManagerImpl implements UserManager {

    private UserSerivce userSerivce = new UserServiceImpl();
    private LoginHistoryService loginHistoryService = new LoginHistoryServiceImpl();

    @Override
    public void login(User user) {
        userSerivce.login(user);
        loginHistoryService.addUserLoginHistory();
    }
}
